package com.fh.member.controller;


import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.fh.member.entity.UmsMemberLevel;
import com.fh.member.service.IUmsMemberLevelService;
import com.fh.result.ResultObject;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 * 会员等级表 前端控制器
 * </p>
 *
 * @author F
 * @since 2021-05-25
 */
@RestController
@RequestMapping("/ums/member-level")
public class UmsMemberLevelController {

    @Autowired
    private IUmsMemberLevelService umsMemberLevelService;


    @GetMapping("/price")
    public ResultObject gerMemberLevel(){
        QueryWrapper<UmsMemberLevel>queryWrapper=new QueryWrapper<>();
        queryWrapper.eq("default_Status", 0);
        queryWrapper.orderByAsc("growth_Point");
        List<UmsMemberLevel>list=umsMemberLevelService.list(queryWrapper);
        return ResultObject.success(list);
    }
}
